package com.easyboot.web.system.domain;

import cn.afterturn.easypoi.excel.annotation.Excel;
import cn.afterturn.easypoi.excel.annotation.ExcelIgnore;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

/**
 * @author YUSHUO
 * @TableName sys_user
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class SysUser implements Serializable {
    /**
     * 用户id
     *
     * @mbg.generated Fri Jan 29 17:21:01 CST 2021
     */
    @TableId(value = "id",type =IdType.INPUT)
    @ExcelIgnore
    private Long id;

    /**
     * 登录账号
     *
     * @mbg.generated Fri Jan 29 17:21:01 CST 2021
     */
    @Excel(name ="登录名",orderNum="1",width = 30)
    private String loginName;

    /**
     * 密码
     *
     * @mbg.generated Fri Jan 29 17:21:01 CST 2021
     */
    @ExcelIgnore
    private String passWord;

    /**
     * 用户名
     *
     * @mbg.generated Fri Jan 29 17:21:01 CST 2021
     */
    @Excel(name ="用户名",orderNum="2",width = 30)
    private String userName;

    /**
     * 手机号码
     *
     * @mbg.generated Fri Jan 29 17:21:01 CST 2021
     */
    @Excel(name ="手机号码",orderNum="3",width = 30)
    private String mobilePhone;

    /**
     * 邮箱
     *
     * @mbg.generated Fri Jan 29 17:21:01 CST 2021
     */
    @Excel(name ="邮箱",orderNum="4",width =50)
    private String email;

    /**
     * 用户性别（1男 0女 2未知）
     *
     * @mbg.generated Fri Jan 29 17:21:01 CST 2021
     */
    @Excel(name ="性别",replace = {"男_1", "女_0","未知_2"},orderNum="5",width = 30)
    private int gender=1;

    /**
     * 是否是超管(0-不是，1-是)
     *
     * @mbg.generated Fri Jan 29 17:21:01 CST 2021
     */
    @ExcelIgnore
    private int isSuper=0;

    /**
     * 角色id
     *
     * @mbg.generated Fri Jan 29 17:21:01 CST 2021
     */
    @ExcelIgnore
    private Long roleId=0L;

    /**
     * 部门
     *
     * @mbg.generated Fri Jan 29 17:21:01 CST 2021
     */
    @ExcelIgnore
    private int deptId=0;

    /**
     * 备注
     *
     * @mbg.generated Fri Jan 29 17:21:01 CST 2021
     */
    private String remark;

    /**
     * 账号状态(1正常，0-禁用)
     *
     * @mbg.generated Fri Jan 29 17:21:01 CST 2021
     */
    @Excel(name ="用户状态",replace = {"正常_1", "禁用_0"},orderNum="6",width = 30)
    private int userStatus=0;

    /**
     * 删除标志（0代表存在 1代表删除）
     *
     * @mbg.generated Fri Jan 29 17:21:01 CST 2021
     */
    @ExcelIgnore
    private Integer delFlag=0;

    /**
     * 创建人
     *
     * @mbg.generated Fri Jan 29 17:21:01 CST 2021
     */
    @ExcelIgnore
    private String createBy;

    /**
     * 创建时间
     *
     * @mbg.generated Fri Jan 29 17:21:01 CST 2021
     */
    @Excel(name ="创建时间",exportFormat = "yyyy-MM-dd HH:mm:ss",orderNum="7",width = 30)
    private Date createTime;
    /**
     * 更新人
     *
     * @mbg.generated Fri Jan 29 17:21:01 CST 2021
     */
    @ExcelIgnore
    private String updateBy;

    @ExcelIgnore
    @TableField(exist = false)
    private List<Long> positionList;



    /**
     * 更新时间
     *
     * @mbg.generated Fri Jan 29 17:21:01 CST 2021
     */
    private Date updateTime;
    private String deptName;

    private String userAvatar;



    /**
    *
     * @author yushuo
     * @description //用户关联的角色
     * @date 14:13 2021/2/2
     * @param
     * @return
    **/
    @TableField(exist = false)
    private String roleName;

    /**
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database table sys_user
     *
     * @mbg.generated Fri Jan 29 17:21:01 CST 2021
     */
    private static final long serialVersionUID = 1L;


}